<?php
session_start();
$action=$_GET["action"];
if($action=='checkCode'){
    if($_SESSION['code']==strtoupper($_POST["code"])){
        echo 1;exit;
    }else{
        echo 0;exit;
    }
}
?>
